<#include "/common/head.ftl">

<@showTitle title="${i18n.getMessage('operatingStatus')} > ${i18n.getMessage('report.monthly')}">
</@showTitle>

<div id="error" style="display:none"></div>

<form id="form">
	<table id="dataTable" cellspacing="5" cellpadding="0" align="center"><tr>
		<td class="name"><@required/>${i18n.getMessage('month')} / ${i18n.getMessage('year')}:</td>
		<td><select name="month" id="month">
			<#list 1..12 as month>
				<option value="${month}" <#if month?string('00')=now?string('MM')>selected</#if>>${month?string('00')}</option>
			</#list>
		</select> / <select name="year" id="year">
			<#list 2007..2020 as year>
				<option value="${year}" <#if year?string=now?string('yyyy')>selected</#if>>${year}</option>
			</#list>
		</select></td>
	</tr><tr>
		<td class="name"></td>
		<td><input type="button" value="Export to Excel" onclick="reportToExcel()" class="button_style w100"/>
		</td>
	</tr></table>
</form>

<script>
reportToExcel = function() {
	pp('system/exportOperatingStatusExcel.sgt?month=' + 
		$('month').value + '&year=' + $('year').value); 
}
</script>